package com.xinzhidi.web.netty.entity.vo;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.xinzhidi.common.annotation.Excel;
import com.xinzhidi.common.utils.DateUtils;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.util.Date;


/**
 * 指令发送ListVo对象 device_instruction
 *
 * @author cx
 * @date 2023-06-16
 */
@ApiModel(value = "指令发送ListVo对象")
@Data
@EqualsAndHashCode(callSuper = false)
public class DeviceInstructionListVo {
    private static final long serialVersionUID = 1L;

    private Long id;

    @ApiModelProperty(value = "dtuId")
    @Excel(name = "dtuId")
    private Long dtuId;

    @ApiModelProperty(value = "dtu名称")
    @Excel(name = "dtu名称")
    private String dtuName;

    private String protocolType;

    @ApiModelProperty(value = "协议名称")
    @Excel(name = "协议名称")
    private String protocolName;

    @ApiModelProperty(value = "指令类型")
    @Excel(name = "指令类型")
    private String instructType;

    @ApiModelProperty(value = "指令名称")
    @Excel(name = "指令名称")
    private String instructName;

    @ApiModelProperty(value = "小区id")
    @Excel(name = "小区id")
    private Long plotId;

    @ApiModelProperty(value = "小区名称")
    @Excel(name = "小区名称")
    private String plotName;

    @ApiModelProperty(value = "楼栋id")
    @Excel(name = "楼栋id")
    private Long buildId;

    @ApiModelProperty(value = "楼栋名称")
    @Excel(name = "楼栋名称")
    private String buildName;

    @ApiModelProperty(value = "单元id")
    @Excel(name = "单元id")
    private Long unitId;

    @ApiModelProperty(value = "单元名称")
    @Excel(name = "单元名称")
    private String unitName;

    @ApiModelProperty(value = "住户id")
    @Excel(name = "住户id")
    private Long householdId;

    @ApiModelProperty(value = "门牌号")
    private String houseNumber;

    @ApiModelProperty(value = "地址域")
    @Excel(name = "地址域")
    private String address;

    @ApiModelProperty(value = "指令集合(十六进制)")
    @Excel(name = "指令集合(十六进制)")
    private String instructionSet;

    @ApiModelProperty(value = "回复数据（十六进制）")
    private String recoverMessage;

    @ApiModelProperty(value = "设备数据")
    @Excel(name = "设备数据")
    private String jsonData;

    @ApiModelProperty(value = "状态（0：待发送 1：已发送 2：发送失败  3：回复正常 4：回复异常  5：回复超时）")
    @Excel(name = "状态", readConverterExp = "0=：待发送,1=：已发送,2=：发送失败,3=：回复正常,4=：回复异常,5=：回复超时")
    private String status;

    @ApiModelProperty(value = "创建时间")
    @JsonFormat(pattern = DateUtils.YYYY_MM_DD_HH_MM_SS)
    private Date createTime;

    @ApiModelProperty(value = "设备回复时间")
    @JsonFormat(pattern = DateUtils.YYYY_MM_DD_HH_MM_SS)
    private Date updateTime;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty(value = "消息发送失败时间")
    private Date sendFailTime;

}
